#ifndef DSPSIMULATOR_INSTRUCTION_SPLOOPD_H
#define DSPSIMULATOR_INSTRUCTION_SPLOOPD_H

#include "dspSimulator/targetMachine/dspInstruction.h"

namespace dspsimulator {
    class SPLOOPD : public DspInstruction {
    public:
        explicit SPLOOPD(u64 address = 0, u32 size = 4) :
                DspInstruction("SPLOOPD", address, size) {}

        SPLOOPD(const SPLOOPD &) = default;

        SPLOOPD(SPLOOPD &&) = default;

        SPLOOPD &operator=(const SPLOOPD &) = default;

        SPLOOPD &operator=(SPLOOPD &&) = default;

        u32 ii() const { return m_ii; }

        std::string to_string() const override;

        std::shared_ptr<Instruction> clone() const override { return std::make_shared<SPLOOPD>(*this); }

    protected:
        std::shared_ptr<DspInstruction> decode_standard_instruction(const std::shared_ptr<DspInstructionInfo> &dsp_instruction_info) override;

        std::shared_ptr<DspInstruction> decode_compact_instruction(const std::shared_ptr<DspInstructionInfo> &dsp_instruction_info) override;

    private:
        u32 m_ii{0};
    };
}

#endif //DSPSIMULATOR_INSTRUCTION_SPLOOPD_H
